<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.11"/>
<title>Cheetah Software: butterworth_filter&lt; T &gt; Class Template Reference</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../jquery.js"></script>
<script type="text/javascript" src="../../dynsections.js"></script>
<link href="../../navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../resize.js"></script>
<script type="text/javascript" src="../../navtreedata.js"></script>
<script type="text/javascript" src="../../navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
  $(window).load(resizeHeight);
</script>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="../../search/searchdata.js"></script>
<script type="text/javascript" src="../../search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { init_search(); });
</script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">Cheetah Software
   &#160;<span id="projectnumber">1.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.11 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "../../search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="../../index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="../../namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="../../annotated.html"><span>Classes</span></a></li>
      <li><a href="../../files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="../../search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="../../annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="../../classes.html"><span>Class&#160;Index</span></a></li>
      <li><a href="../../inherits.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="../../functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('de/d79/classbutterworth__filter.html','../../');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pri-attribs">Private Attributes</a> &#124;
<a href="../../d6/d90/classbutterworth__filter-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">butterworth_filter&lt; T &gt; Class Template Reference</div>  </div>
</div><!--header-->
<div class="contents">

<p><code>#include &lt;<a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>&gt;</code></p>
<div id="dynsection-0" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
  <img id="dynsection-0-trigger" src="../../closed.png" alt="+"/> Inheritance diagram for butterworth_filter&lt; T &gt;:</div>
<div id="dynsection-0-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-0-content" class="dyncontent" style="display:none;">
<div class="center"><img src="../../d9/d2d/classbutterworth__filter__inherit__graph.png" border="0" usemap="#butterworth__filter_3_01_t_01_4_inherit__map" alt="Inheritance graph"/></div>
<map name="butterworth__filter_3_01_t_01_4_inherit__map" id="butterworth__filter_3_01_t_01_4_inherit__map">
</map>
</div>
<div id="dynsection-1" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
  <img id="dynsection-1-trigger" src="../../closed.png" alt="+"/> Collaboration diagram for butterworth_filter&lt; T &gt;:</div>
<div id="dynsection-1-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-1-content" class="dyncontent" style="display:none;">
<div class="center"><img src="../../dd/dc1/classbutterworth__filter__coll__graph.png" border="0" usemap="#butterworth__filter_3_01_t_01_4_coll__map" alt="Collaboration graph"/></div>
<map name="butterworth__filter_3_01_t_01_4_coll__map" id="butterworth__filter_3_01_t_01_4_coll__map">
</map>
</div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:abd0d354a0ee960e8cd64be3561b42aff"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#abd0d354a0ee960e8cd64be3561b42aff">butterworth_filter</a> (int num_sample, T dt, T cutoff_frequency)</td></tr>
<tr class="separator:abd0d354a0ee960e8cd64be3561b42aff"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae8d9d4d155bfbadd0c4adab1071721f9"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#ae8d9d4d155bfbadd0c4adab1071721f9">~butterworth_filter</a> (void)</td></tr>
<tr class="separator:ae8d9d4d155bfbadd0c4adab1071721f9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae4cd1f9cdcba1e2012ed006d16a23cb4"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#ae4cd1f9cdcba1e2012ed006d16a23cb4">input</a> (T input_value)</td></tr>
<tr class="separator:ae4cd1f9cdcba1e2012ed006d16a23cb4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af2856071043e4b41174e9d40d49cb99f"><td class="memItemLeft" align="right" valign="top">virtual T&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#af2856071043e4b41174e9d40d49cb99f">output</a> (void)</td></tr>
<tr class="separator:af2856071043e4b41174e9d40d49cb99f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acf63a517e54783f55887343818e3ae78"><td class="memItemLeft" align="right" valign="top">virtual void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#acf63a517e54783f55887343818e3ae78">clear</a> (void)</td></tr>
<tr class="separator:acf63a517e54783f55887343818e3ae78"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="inherit_header pub_methods_classfilter"><td colspan="2" onclick="javascript:toggleInherit('pub_methods_classfilter')"><img src="../../closed.png" alt="-"/>&#160;Public Member Functions inherited from <a class="el" href="../../db/db7/classfilter.html">filter&lt; T &gt;</a></td></tr>
<tr class="memitem:a1acf714cdea22d29c669fb14840f97a2 inherit pub_methods_classfilter"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/db7/classfilter.html#a1acf714cdea22d29c669fb14840f97a2">filter</a> (void)</td></tr>
<tr class="separator:a1acf714cdea22d29c669fb14840f97a2 inherit pub_methods_classfilter"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0be0ee0b051f2bb824623a11545b662a inherit pub_methods_classfilter"><td class="memItemLeft" align="right" valign="top">virtual&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../db/db7/classfilter.html#a0be0ee0b051f2bb824623a11545b662a">~filter</a> (void)</td></tr>
<tr class="separator:a0be0ee0b051f2bb824623a11545b662a inherit pub_methods_classfilter"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pri-attribs"></a>
Private Attributes</h2></td></tr>
<tr class="memitem:ab330a0c99e4b3b7a0c3be05c93309196"><td class="memItemLeft" align="right" valign="top">T *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a></td></tr>
<tr class="separator:ab330a0c99e4b3b7a0c3be05c93309196"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6e2b77a3be992b9ad4fa6ad89bd7c4da"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#a6e2b77a3be992b9ad4fa6ad89bd7c4da">mCurIdx</a></td></tr>
<tr class="separator:a6e2b77a3be992b9ad4fa6ad89bd7c4da"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abad817a154b49329db712aea66a590d2"><td class="memItemLeft" align="right" valign="top">int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">mNumSample</a></td></tr>
<tr class="separator:abad817a154b49329db712aea66a590d2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a67f7ccaf6623507e75e6a44f8114dc2c"><td class="memItemLeft" align="right" valign="top">T&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#a67f7ccaf6623507e75e6a44f8114dc2c">mDt</a></td></tr>
<tr class="separator:a67f7ccaf6623507e75e6a44f8114dc2c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6f4157c9b1cd9aff3583634e667d3a0c"><td class="memItemLeft" align="right" valign="top">T&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#a6f4157c9b1cd9aff3583634e667d3a0c">mCutoffFreq</a></td></tr>
<tr class="separator:a6f4157c9b1cd9aff3583634e667d3a0c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8a053d738d0d50b24f9ba544b0ccaed4"><td class="memItemLeft" align="right" valign="top">T&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="../../de/d79/classbutterworth__filter.html#a8a053d738d0d50b24f9ba544b0ccaed4">mValue</a></td></tr>
<tr class="separator:a8a053d738d0d50b24f9ba544b0ccaed4"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;typename T&gt;<br />
class butterworth_filter&lt; T &gt;</h3>


<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00015">15</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="abd0d354a0ee960e8cd64be3561b42aff"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::<a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a> </td>
          <td>(</td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>num_sample</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">T&#160;</td>
          <td class="paramname"><em>dt</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">T&#160;</td>
          <td class="paramname"><em>cutoff_frequency</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/de4/filters_8cpp_source.html#l00047">47</a> of file <a class="el" href="../../dc/de4/filters_8cpp_source.html">filters.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;                                                              {</div><div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">mNumSample</a> = num_sample;</div><div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#a67f7ccaf6623507e75e6a44f8114dc2c">mDt</a> = dt;</div><div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#a6f4157c9b1cd9aff3583634e667d3a0c">mCutoffFreq</a> = cutoff_frequency;</div><div class="line"><a name="l00052"></a><span class="lineno">   52</span>&#160;</div><div class="line"><a name="l00053"></a><span class="lineno">   53</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a> = <span class="keyword">new</span> T[num_sample];</div><div class="line"><a name="l00054"></a><span class="lineno">   54</span>&#160;  memset((<span class="keywordtype">void</span> *)<a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>, 0, <span class="keyword">sizeof</span>(T) * num_sample);</div><div class="line"><a name="l00055"></a><span class="lineno">   55</span>&#160;</div><div class="line"><a name="l00056"></a><span class="lineno">   56</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#a6e2b77a3be992b9ad4fa6ad89bd7c4da">mCurIdx</a> = 0;</div><div class="line"><a name="l00057"></a><span class="lineno">   57</span>&#160;}</div><div class="ttc" id="classbutterworth__filter_html_a6e2b77a3be992b9ad4fa6ad89bd7c4da"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a6e2b77a3be992b9ad4fa6ad89bd7c4da">butterworth_filter::mCurIdx</a></div><div class="ttdeci">int mCurIdx</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00025">filters.h:25</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_abad817a154b49329db712aea66a590d2"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">butterworth_filter::mNumSample</a></div><div class="ttdeci">int mNumSample</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00026">filters.h:26</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_ab330a0c99e4b3b7a0c3be05c93309196"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">butterworth_filter::mpBuffer</a></div><div class="ttdeci">T * mpBuffer</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00024">filters.h:24</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_a6f4157c9b1cd9aff3583634e667d3a0c"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a6f4157c9b1cd9aff3583634e667d3a0c">butterworth_filter::mCutoffFreq</a></div><div class="ttdeci">T mCutoffFreq</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00028">filters.h:28</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_a67f7ccaf6623507e75e6a44f8114dc2c"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a67f7ccaf6623507e75e6a44f8114dc2c">butterworth_filter::mDt</a></div><div class="ttdeci">T mDt</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00027">filters.h:27</a></div></div>
</div><!-- fragment -->
</div>
</div>
<a class="anchor" id="ae8d9d4d155bfbadd0c4adab1071721f9"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::~<a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a> </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/de4/filters_8cpp_source.html#l00060">60</a> of file <a class="el" href="../../dc/de4/filters_8cpp_source.html">filters.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00060"></a><span class="lineno">   60</span>&#160;                                               {</div><div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;  <span class="keyword">delete</span>[] <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>;</div><div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;}</div><div class="ttc" id="classbutterworth__filter_html_ab330a0c99e4b3b7a0c3be05c93309196"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">butterworth_filter::mpBuffer</a></div><div class="ttdeci">T * mpBuffer</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00024">filters.h:24</a></div></div>
</div><!-- fragment -->
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="acf63a517e54783f55887343818e3ae78"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::clear </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Implements <a class="el" href="../../db/db7/classfilter.html#ae0e36e8992fc55acceddc7b02a2a711a">filter&lt; T &gt;</a>.</p>

<p>Definition at line <a class="el" href="../../dc/de4/filters_8cpp_source.html#l00089">89</a> of file <a class="el" href="../../dc/de4/filters_8cpp_source.html">filters.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00089"></a><span class="lineno">   89</span>&#160;                                      {</div><div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;  <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i(0); i &lt; <a class="code" href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">mNumSample</a>; ++i) {</div><div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;    <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>[i] = 0.0;</div><div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;  }</div><div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;}</div><div class="ttc" id="classbutterworth__filter_html_abad817a154b49329db712aea66a590d2"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">butterworth_filter::mNumSample</a></div><div class="ttdeci">int mNumSample</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00026">filters.h:26</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_ab330a0c99e4b3b7a0c3be05c93309196"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">butterworth_filter::mpBuffer</a></div><div class="ttdeci">T * mpBuffer</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00024">filters.h:24</a></div></div>
</div><!-- fragment -->
</div>
</div>
<a class="anchor" id="ae4cd1f9cdcba1e2012ed006d16a23cb4"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::input </td>
          <td>(</td>
          <td class="paramtype">T&#160;</td>
          <td class="paramname"><em>input_value</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Implements <a class="el" href="../../db/db7/classfilter.html#a968cd36e3cca3fb8541d4a57510aca4f">filter&lt; T &gt;</a>.</p>

<p>Definition at line <a class="el" href="../../dc/de4/filters_8cpp_source.html#l00065">65</a> of file <a class="el" href="../../dc/de4/filters_8cpp_source.html">filters.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;                                               {</div><div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;  <span class="keywordtype">int</span> j;</div><div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;  T sqrt_2 = sqrt(2);</div><div class="line"><a name="l00068"></a><span class="lineno">   68</span>&#160;  T value = 0;</div><div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;  <span class="keywordflow">for</span> (j = <a class="code" href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">mNumSample</a> - 2; j &gt;= 0; j--) {</div><div class="line"><a name="l00070"></a><span class="lineno">   70</span>&#160;    <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>[j + 1] = <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>[j];</div><div class="line"><a name="l00071"></a><span class="lineno">   71</span>&#160;  }</div><div class="line"><a name="l00072"></a><span class="lineno">   72</span>&#160;</div><div class="line"><a name="l00073"></a><span class="lineno">   73</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>[0] = input_value;</div><div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;  <span class="keywordflow">for</span> (j = 0; j &lt; <a class="code" href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">mNumSample</a>; j++) {</div><div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;    T t = (T)j * <a class="code" href="../../de/d79/classbutterworth__filter.html#a67f7ccaf6623507e75e6a44f8114dc2c">mDt</a>;</div><div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;    value += sqrt_2 / <a class="code" href="../../de/d79/classbutterworth__filter.html#a6f4157c9b1cd9aff3583634e667d3a0c">mCutoffFreq</a> * <a class="code" href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">mpBuffer</a>[j] * exp(-1. / sqrt_2 * t) *</div><div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;             sin(<a class="code" href="../../de/d79/classbutterworth__filter.html#a6f4157c9b1cd9aff3583634e667d3a0c">mCutoffFreq</a> / sqrt_2 * t) * <a class="code" href="../../de/d79/classbutterworth__filter.html#a67f7ccaf6623507e75e6a44f8114dc2c">mDt</a>;</div><div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;    <span class="comment">//    value += sqrt_2 * exp(-1./sqrt_2*t) * sin(1./sqrt_2*t ) * mDt;</span></div><div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160;  }</div><div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;  <a class="code" href="../../de/d79/classbutterworth__filter.html#a8a053d738d0d50b24f9ba544b0ccaed4">mValue</a> = value;</div><div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;}</div><div class="ttc" id="classbutterworth__filter_html_abad817a154b49329db712aea66a590d2"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#abad817a154b49329db712aea66a590d2">butterworth_filter::mNumSample</a></div><div class="ttdeci">int mNumSample</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00026">filters.h:26</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_ab330a0c99e4b3b7a0c3be05c93309196"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#ab330a0c99e4b3b7a0c3be05c93309196">butterworth_filter::mpBuffer</a></div><div class="ttdeci">T * mpBuffer</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00024">filters.h:24</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_a6f4157c9b1cd9aff3583634e667d3a0c"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a6f4157c9b1cd9aff3583634e667d3a0c">butterworth_filter::mCutoffFreq</a></div><div class="ttdeci">T mCutoffFreq</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00028">filters.h:28</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_a67f7ccaf6623507e75e6a44f8114dc2c"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a67f7ccaf6623507e75e6a44f8114dc2c">butterworth_filter::mDt</a></div><div class="ttdeci">T mDt</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00027">filters.h:27</a></div></div>
<div class="ttc" id="classbutterworth__filter_html_a8a053d738d0d50b24f9ba544b0ccaed4"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a8a053d738d0d50b24f9ba544b0ccaed4">butterworth_filter::mValue</a></div><div class="ttdeci">T mValue</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00029">filters.h:29</a></div></div>
</div><!-- fragment -->
</div>
</div>
<a class="anchor" id="af2856071043e4b41174e9d40d49cb99f"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">T <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::output </td>
          <td>(</td>
          <td class="paramtype">void&#160;</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">virtual</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Implements <a class="el" href="../../db/db7/classfilter.html#a368417e744fae19145dc46bd878216e5">filter&lt; T &gt;</a>.</p>

<p>Definition at line <a class="el" href="../../dc/de4/filters_8cpp_source.html#l00084">84</a> of file <a class="el" href="../../dc/de4/filters_8cpp_source.html">filters.cpp</a>.</p>
<div class="fragment"><div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160;                                    {</div><div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160;  <span class="keywordflow">return</span> <a class="code" href="../../de/d79/classbutterworth__filter.html#a8a053d738d0d50b24f9ba544b0ccaed4">mValue</a>;</div><div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;}</div><div class="ttc" id="classbutterworth__filter_html_a8a053d738d0d50b24f9ba544b0ccaed4"><div class="ttname"><a href="../../de/d79/classbutterworth__filter.html#a8a053d738d0d50b24f9ba544b0ccaed4">butterworth_filter::mValue</a></div><div class="ttdeci">T mValue</div><div class="ttdef"><b>Definition:</b> <a href="../../dc/ddd/filters_8h_source.html#l00029">filters.h:29</a></div></div>
</div><!-- fragment -->
</div>
</div>
<h2 class="groupheader">Member Data Documentation</h2>
<a class="anchor" id="a6e2b77a3be992b9ad4fa6ad89bd7c4da"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::mCurIdx</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00025">25</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>

</div>
</div>
<a class="anchor" id="a6f4157c9b1cd9aff3583634e667d3a0c"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">T <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::mCutoffFreq</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00028">28</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>

</div>
</div>
<a class="anchor" id="a67f7ccaf6623507e75e6a44f8114dc2c"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">T <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::mDt</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00027">27</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>

</div>
</div>
<a class="anchor" id="abad817a154b49329db712aea66a590d2"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">int <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::mNumSample</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00026">26</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>

</div>
</div>
<a class="anchor" id="ab330a0c99e4b3b7a0c3be05c93309196"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">T* <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::mpBuffer</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00024">24</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>

</div>
</div>
<a class="anchor" id="a8a053d738d0d50b24f9ba544b0ccaed4"></a>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename T &gt; </div>
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">T <a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a>&lt; T &gt;::mValue</td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">private</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="../../dc/ddd/filters_8h_source.html#l00029">29</a> of file <a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li><a class="el" href="../../dc/ddd/filters_8h_source.html">filters.h</a></li>
<li><a class="el" href="../../dc/de4/filters_8cpp_source.html">filters.cpp</a></li>
</ul>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="../../de/d79/classbutterworth__filter.html">butterworth_filter</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.8.11 </li>
  </ul>
</div>
</body>
</html>
